package com.yc.jiushujie.jsj_index.web;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yc.jiushujie.entity.JsjBook;
import com.yc.jiushujie.entity.JsjCategory;
import com.yc.jiushujie.entity.JsjSearch;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

@FeignClient("jsj-order")
public interface IOrderAction {
    @GetMapping("/jiushujie/jsjBook/queryHao")
    List<JsjBook>queryHao();//index查好书推荐
    @GetMapping("/jiushujie/jsjSearch/queryHotsou")
    List<JsjSearch>queryHotsou();//查标题中的热搜
    @GetMapping("/jiushujie/jsjBook/findById")
   JsjBook findById(@RequestParam int id);//根据书id查书
//    @GetMapping("/jiushujie/jsjBook/queryUserByBid")
//    List<JsjBook>queryUserByBid(@RequestParam int bid);
@GetMapping("/jiushujie/jsjBook/getowner")//查书的拥有者
    JsjBook getowner(@RequestParam int id);
@GetMapping("/jiushujie/jsjCategory/queryCategory")
    List<JsjCategory> queryCategory();
    @GetMapping("/jiushujie/jsjBook/queryAllBook")
    Page<JsjBook> queryAllBook(@RequestParam int page,@RequestParam int size);//查所有
}
